# -*- mode: snippet -*-
# name: frequency/contingency table in dplyr, prop.table
# key: dplyr.frequency.contingency
# --
  group_by(${1:group}, ${2:factor}) |>
  summarise(${3:n} = n()) |>
  mutate(${4:p} = prop.table($3))
